import { FC } from 'react';
import { Redirect, Route, Switch } from 'react-router-dom';
import AppFoodCategory from '../AppFoodCategory';
import AppFoodDetail from '../AppFoodDetail';
import AppMain from '../AppLayout/AppMain';
import AppMemberCard from '../AppMemberCard';
import AppMemberPoint from '../AppMemberPoint';
import AppMemberProfile from '../AppMemberProfile';
import AppNotFound from '../AppNotFound';
import AppRoomDesk from '../AppRoomDesk';
import AppRoomList from '../AppRoomList';
import AppSet from '../AppSet';
import AppPayOff from '../AppPayOff';
import AppStore  from '../AppStore';

const AppContent: FC = () => {
  console.log('AppContent')
  return (
    <div className="AppContent">
      <Switch>
        <Redirect from="/" exact to="/home" />
        <Route path="/home" component={AppMain} />
        <Route path="/food-category" component={AppFoodCategory} />
        <Route path="/food-detail" component={AppFoodDetail} />
        <Route path="/room-list" component={AppRoomList} />
        <Route path="/room-desk" component={AppRoomDesk} />
        <Route path="/member-profile" component={AppMemberProfile} />
        <Route path="/member-point" component={AppMemberPoint} />
        <Route path="/member-card" component={AppMemberCard}/>
        <Route path="/set-info" component={AppSet} />
        <Route path="/set-payoff" component={AppPayOff} />
        <Route path="/set-store" component={AppStore} />
        <Route path="/404" component={AppNotFound} />
        <Redirect from="*" to="/404" />
      </Switch>
    </div>
  )
}

export default AppContent
